package com.lhn.spring5.factory;

/**
 * 测试类
 *
 * @author lhn
 * @date 2021/12/28 15:30
 * @since 1.0.0
 **/
public class Foo {

    private BarInterface barInterface;

    //public Foo() {
    //    this.barInterface = StaticBarInterfaceFactory.getInstance();
    //}


    public void setBarInterface(BarInterface barInterface) {
        this.barInterface = barInterface;
    }

    @Override
    public String toString() {
        final StringBuffer sb = new StringBuffer("Foo{");
        sb.append("barInterface=").append(barInterface);
        sb.append('}');
        return sb.toString();
    }
}